<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
       
        .box{
            width: 100px;
            height: 100px;
            background-color: red;
        }
    </style>
    <link href="https://cdn.bootcdn.net/ajax/libs/animate.css/4.1.1/animate.css" rel="stylesheet">
    <script src="../框架相关的js/vue.js"></script>
</head>
<body>
  
    <div id="app">
        <transition class="box" enter-to-class="animate__animated animate__heartBeat"  appear >
            <div v-if="ok" class="box" >toggled content</div>
          </transition>
    </div>

           
      <script>

          new Vue({
              el:'#app',
              data:{
                  ok:'0'
              }
          })
      </script>
</body>
</html>